home *** CD-ROM | disk | FTP | other *** search
/ MacFormat 1997 April / macformat-049.iso / mac / Shareware Plus / Graphics / ImageMapper 2.0beta2 FAT / Map Formats / About Map Formats… next >
Encoding:
Text File  |  1996-11-26  |  2.8 KB  |  53 lines  |  [TEXT/ttxt]

  1. About Map Formats…
  2. ©1996 Stuart Snaddon
  3. -This file is part of the ImageMapper distribution v1.2
  4.  
  5. The latest release of ImageMapper (v1.2+) has a new feature that lets you state exactly how you would like the map generated.
  6.  
  7. Any map files you create that are stored in the same folder as the application, or any subfolders within that folder are auto-listed in the compile dialog. It is recommended that you use the 'Map Formats' folder, but you can put your formats anywhere, and use the 'Load…' command to locate them at compile time.
  8.  
  9. An extremely simple language has been devised to handle this, which can be viewed by opening either of the two supplied formats (NCSA or CERN) in this folder as text files in a program like BBEdit:
  10.  
  11. The file is subdivided into 5 discrete sections, anything outside of a section is ignored, and treated as a comment.
  12.  
  13. The sections are enclosed in html-like tags ie: <TAG> stuff </TAG>. The tags must be capitals, and not embedded within other tags.
  14.  
  15. Currently supported tags are:
  16.  
  17.     HEADER    - usually comment text to be output at the start of the file, but can be
  18.                                  anything.
  19.  
  20.     RECT - decribes how to output each rectangle object. Combination of
  21.                                  straight text to be copied and variables.
  22.                                  Wherever the compiler encounters a $xxxx, it replaces it with the
  23.                                  appropriate value/text.
  24.  
  25.             Variables:
  26.                     $x0 - left x coordinate of boundary rectangle
  27.                     $y0 - top y coordinate of boundary rectangle
  28.                     $x1 - right x coordinate of boundary rectangle
  29.                     $y1 - bottom y coordinate of boundary rectangle
  30.                     $xc - x-coordinate of center of boundary rectangle
  31.                     $yc - y-coordinate of center of boundary rectangle
  32.                     $radius - distance from xc to x0, or from yc to y0 (assumes circle/square)
  33.                     $url    - target of object
  34.     
  35.     CIRCLE - similar to rectangle section, same variables apply.
  36.  
  37.     POLYGON - similar to the last two sections, except there is a variable number of
  38.                                     points, so three new variables are introduced:
  39.  
  40.                 Variables:
  41.                         $xn - x-coordinate of nth point
  42.                         $yn - y-coordinate of nth point
  43.                         …    - repeats following $xn, $yn combination until no more points can be found.
  44.                                         (*** NOTE: it is the single character obtained by typing <option> ‘:’, and
  45.                                                                           not three individual full stops. ***)
  46.  
  47.     FOOTNOTE - exactly the same as header section, but appears at end of file, after all
  48.                                     shapes have been written.
  49.  
  50. NOTE:
  51.         Direct manipulation of these files can be desirable, but is not essential! There is an editor feature built into the program which makes it a lot simpler. You will still need to know the variable names though.
  52.  
  53.         If you do decide to edit the files, or even create new ones, the file type is 'GmAp', and the creator is 'WidT'. If the file type is not right, they won't show up in the dialog.